package com.huawei.java.tools.csvreaders;

import java.io.BufferedReader;
import java.io.IOException;
import java.nio.charset.Charset;
import java.nio.file.Files;
import java.nio.file.Path;
import java.nio.file.Paths;

/**
 * @author henrydai
 * @version 1.0
 * @date 2022/3/15 19:33
 * @description
 */
public class DemandReader {
    public void readFile(String DATA_DIR)
    {
        Path path = Paths.get(DATA_DIR);
        try {
            // Charset.forName("UTF-8")
            BufferedReader br = Files.newBufferedReader(path);

            //处理标题栏
            String s = br.readLine();
            String[] clientNames = s.split(",");
            //todo

            s = br.readLine();
            //处理内容
            while(s!=null)
            {
                //todo
            }

        } catch (IOException e) {
            e.printStackTrace();
        }
    }

}
